﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using rent_car.Manejadores;

namespace rent_car.Gui
{  

    public partial class FormLogin : Form
    {
        public FormLogin()
        {            
            InitializeComponent();
        }       

        private void btnAccesar_Click(object sender, EventArgs e)
        {
            if (ManejadorDeUsuarios.GetInstancia().Acceso(txtUsuario.Text, txtClave.Text))
            {
                this.Hide();
                new FormPrincipal().ShowDialog();
            }
            else {
                lblInvalido.Visible = true;
            }
        }

        private void FormLogin_Load(object sender, EventArgs e)
        {

        }       
    }
}
